﻿<html>
<body>
<script>
 var x;
 var x=6;
 var x="Bill";
 
 var carname1="Bill Gates";
 var carname2 ='Bill Gates';
 
 var answer1="Nice to meet you!";
 var answer2="He is called 'bill'";
 var answer3='He is called "bill"';
 
 document.write(carname1+"</br>");
 document.write(carname2+ "</br>");
 document.write(answer1+"</br>");
 document.write(answer2+"</br>");
 document.write(answer3+"</br>");
 
 
 var x1 =34.00;  //使用小数点来写
 var x2 =34;     //不使用小数点
 
 
 //极大或极小的数字可以通过科学计数法来书写
 var  y = 123e5;    //12300000   
 var z =1233-5;     // 0.00123
 
 var x = true;
 var y = false;
 
 
 //JavaScrpt数组
 var cars = new Array();
 cars[0]="Audi";
 cars[1]="BMW";
 cars[2]="Volvo";
 for(i=0;i<cars.length;i++){
  document.write(cars[i]+"<br>");
 }
 
 </script>
 
 
</body>
</html>